Optimal. Leaf size=96 \[ \frac{1}{4} c d x^4 \left (a+b \tanh ^{-1}(c x)\right )+\frac{1}{3} d x^3 \left (a+b \tanh ^{-1}(c x)\right )+\frac{b d x}{4 c^2}+\frac{7 b d \log (1-c x)}{24 c^3}+\frac{b d \log (c x+1)}{24 c^3}+\frac{b d x^2}{6 c}+\frac{1}{12} b d x^3 \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.0974052, antiderivative size = 96, normalized size of antiderivative = 1., number of steps used = 7, number of rules used = 6, integrand size = 18, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.333, Rules used = {43, 5936, 12, 801, 633, 31} \[ \frac{1}{4} c d x^4 \left (a+b \tanh ^{-1}(c x)\right )+\frac{1}{3} d x^3 \left (a+b \tanh ^{-1}(c x)\right )+\frac{b d x}{4 c^2}+\frac{7 b d \log (1-c x)}{24 c^3}+\frac{b d \log (c x+1)}{24 c^3}+\frac{b d x^2}{6 c}+\frac{1}{12} b d x^3 \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 43
Rule 5936
Rule 12
Rule 801
Rule 633
Rule 31
Rubi steps
\begin{align*} \int x^2 (d+c d x) \left (a+b \tanh ^{-1}(c x)\right ) \, dx &=\frac{1}{3} d x^3 \left (a+b \tanh ^{-1}(c x)\right )+\frac{1}{4} c d x^4 \left (a+b \tanh ^{-1}(c x)\right )-(b c) \int \frac{d x^3 (4+3 c x)}{12 \left (1-c^2 x^2\right )} \, dx\\ &=\frac{1}{3} d x^3 \left (a+b \tanh ^{-1}(c x)\right )+\frac{1}{4} c d x^4 \left (a+b \tanh ^{-1}(c x)\right )-\frac{1}{12} (b c d) \int \frac{x^3 (4+3 c x)}{1-c^2 x^2} \, dx\\ &=\frac{1}{3} d x^3 \left (a+b \tanh ^{-1}(c x)\right )+\frac{1}{4} c d x^4 \left (a+b \tanh ^{-1}(c x)\right )-\frac{1}{12} (b c d) \int \left (-\frac{3}{c^3}-\frac{4 x}{c^2}-\frac{3 x^2}{c}+\frac{3+4 c x}{c^3 \left (1-c^2 x^2\right )}\right ) \, dx\\ &=\frac{b d x}{4 c^2}+\frac{b d x^2}{6 c}+\frac{1}{12} b d x^3+\frac{1}{3} d x^3 \left (a+b \tanh ^{-1}(c x)\right )+\frac{1}{4} c d x^4 \left (a+b \tanh ^{-1}(c x)\right )-\frac{(b d) \int \frac{3+4 c x}{1-c^2 x^2} \, dx}{12 c^2}\\ &=\frac{b d x}{4 c^2}+\frac{b d x^2}{6 c}+\frac{1}{12} b d x^3+\frac{1}{3} d x^3 \left (a+b \tanh ^{-1}(c x)\right )+\frac{1}{4} c d x^4 \left (a+b \tanh ^{-1}(c x)\right )-\frac{(b d) \int \frac{1}{-c-c^2 x} \, dx}{24 c}-\frac{(7 b d) \int \frac{1}{c-c^2 x} \, dx}{24 c}\\ &=\frac{b d x}{4 c^2}+\frac{b d x^2}{6 c}+\frac{1}{12} b d x^3+\frac{1}{3} d x^3 \left (a+b \tanh ^{-1}(c x)\right )+\frac{1}{4} c d x^4 \left (a+b \tanh ^{-1}(c x)\right )+\frac{7 b d \log (1-c x)}{24 c^3}+\frac{b d \log (1+c x)}{24 c^3}\\ \end{align*}
Mathematica [A] time = 0.0631771, size = 87, normalized size = 0.91 \[ \frac{d \left (6 a c^4 x^4+8 a c^3 x^3+2 b c^3 x^3+4 b c^2 x^2+2 b c^3 x^3 (3 c x+4) \tanh ^{-1}(c x)+6 b c x+7 b \log (1-c x)+b \log (c x+1)\right )}{24 c^3} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [A] time = 0.032, size = 91, normalized size = 1. \begin{align*}{\frac{cda{x}^{4}}{4}}+{\frac{da{x}^{3}}{3}}+{\frac{cdb{\it Artanh} \left ( cx \right ){x}^{4}}{4}}+{\frac{db{\it Artanh} \left ( cx \right ){x}^{3}}{3}}+{\frac{bd{x}^{3}}{12}}+{\frac{bd{x}^{2}}{6\,c}}+{\frac{bdx}{4\,{c}^{2}}}+{\frac{7\,db\ln \left ( cx-1 \right ) }{24\,{c}^{3}}}+{\frac{db\ln \left ( cx+1 \right ) }{24\,{c}^{3}}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [A] time = 0.948211, size = 149, normalized size = 1.55 \begin{align*} \frac{1}{4} \, a c d x^{4} + \frac{1}{3} \, a d x^{3} + \frac{1}{24} \,{\left (6 \, x^{4} \operatorname{artanh}\left (c x\right ) + c{\left (\frac{2 \,{\left (c^{2} x^{3} + 3 \, x\right )}}{c^{4}} - \frac{3 \, \log \left (c x + 1\right )}{c^{5}} + \frac{3 \, \log \left (c x - 1\right )}{c^{5}}\right )}\right )} b c d + \frac{1}{6} \,{\left (2 \, x^{3} \operatorname{artanh}\left (c x\right ) + c{\left (\frac{x^{2}}{c^{2}} + \frac{\log \left (c^{2} x^{2} - 1\right )}{c^{4}}\right )}\right )} b d \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [A] time = 2.04877, size = 240, normalized size = 2.5 \begin{align*} \frac{6 \, a c^{4} d x^{4} + 2 \,{\left (4 \, a + b\right )} c^{3} d x^{3} + 4 \, b c^{2} d x^{2} + 6 \, b c d x + b d \log \left (c x + 1\right ) + 7 \, b d \log \left (c x - 1\right ) +{\left (3 \, b c^{4} d x^{4} + 4 \, b c^{3} d x^{3}\right )} \log \left (-\frac{c x + 1}{c x - 1}\right )}{24 \, c^{3}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 2.58851, size = 112, normalized size = 1.17 \begin{align*} \begin{cases} \frac{a c d x^{4}}{4} + \frac{a d x^{3}}{3} + \frac{b c d x^{4} \operatorname{atanh}{\left (c x \right )}}{4} + \frac{b d x^{3} \operatorname{atanh}{\left (c x \right )}}{3} + \frac{b d x^{3}}{12} + \frac{b d x^{2}}{6 c} + \frac{b d x}{4 c^{2}} + \frac{b d \log{\left (x - \frac{1}{c} \right )}}{3 c^{3}} + \frac{b d \operatorname{atanh}{\left (c x \right )}}{12 c^{3}} & \text{for}\: c \neq 0 \\\frac{a d x^{3}}{3} & \text{otherwise} \end{cases} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [A] time = 1.24663, size = 134, normalized size = 1.4 \begin{align*} \frac{1}{4} \, a c d x^{4} + \frac{1}{12} \,{\left (4 \, a d + b d\right )} x^{3} + \frac{b d x^{2}}{6 \, c} + \frac{1}{24} \,{\left (3 \, b c d x^{4} + 4 \, b d x^{3}\right )} \log \left (-\frac{c x + 1}{c x - 1}\right ) + \frac{b d x}{4 \, c^{2}} + \frac{b d \log \left (c x + 1\right )}{24 \, c^{3}} + \frac{7 \, b d \log \left (c x - 1\right )}{24 \, c^{3}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]